const path = require('path');

module.exports = {
  devtool: 'eval-source-map',
  mode: 'development',
  entry:{
    index: path.resolve(__dirname, './src/js/index.js'),
    login: path.resolve(__dirname, './src/js/login.js'),
    Ajax: path.resolve(__dirname, './src/js/Ajax.js'),
    Auth: path.resolve(__dirname, './src/js/Auth.js'),
    upload_img: path.resolve(__dirname, './src/js/upload_img.js')
  },
  output: {
    path: path.resolve(__dirname, './dist/js'),
    filename: '[name].js'
  },
  module: {
    rules: [
      {
        test: /\.js$/,
        use: {
          loader: "babel-loader"
        },
        exclude: /node_modules/
      }
    ]
  }
}